// import type { RouteRecordRaw } from "vue-router";

interface RoutesProps {
  path: string;
  name: string;
  component: string;
  [key: string]: any;
}

const studentsRoutes: Array<RoutesProps> = [
  {
    path: "/home",
    name: "StudentsHome",
    component: "students/StudentsHome/StudentsHome",
    meta: {
      title: "工作台",
      icon: "",
      alwaysShow: 0, // 1 显示菜单，0不显示菜单
    },
  },
  {
    path: "",
    name: "",
    component: "",
    meta: {
      title: "考试题库",
      icon: "",
      alwaysShow: 1,
    },
    children: [
      {
        path: "/createexaminationpaper",
        name: "createexaminationpaper",
        component: "students/CreateExaminationPaper/CreateExaminationPaper",
        meta: {
          title: "生成试卷",
          icon: "",
          alwaysShow: 1,
        },
      },
      {
        path: "/examinationpaperlist",
        name: "examinationpaperlist",
        component: "students/ExaminationPaperList/ExaminationPaperList",
        meta: {
          title: "查看试卷列表",
          icon: "",
          alwaysShow: 1,
        },
      },
      {
        path: "/answerresult",
        name: "answerresult",
        component: "students/AnswerTheExamination/AnswerTheExamination",
        meta: {
          title: "错题解析",
          icon: "",
          alwaysShow: 0,
        },
      },
    ],
  },
  {
    path: "",
    name: "",
    component: "",
    meta: {
      title: "开始考试",
      icon: "",
      alwaysShow: 0,
    },
    children: [
      {
        path: "/answertheexamination",
        name: "answertheexamination",
        component: "students/AnswerTheExamination/AnswerTheExamination",
        meta: {
          title: "开始答题",
          icon: "",
          alwaysShow: 0,
        },
      },
      {
        path: "/examinationresult",
        name: "examinationresult",
        component: "students/ExaminationResult/ExaminationResult",
        meta: {
          title: "生成考试分数",
          icon: "",
          alwaysShow: 0,
        },
      },
    ],
  },
  {
    path: "/personalcenter",
    name: "personalcenter",
    component: "students/PersonalCenter/PersonalCenter",
    meta: {
      title: "个人中心",
      icon: "",
      alwaysShow: 1,
    },
  },
  {
    path: "/:pathMatch(.*)",
    name: "",
    redirect: "/notfound",
    component: "",
    meta: {
      title: "",
      icon: "",
      alwaysShow: 0,
    },
  },
];

export default studentsRoutes;
